package com.sky.mapper;

import com.sky.dto.ArticleCommentDTO;
import com.sky.dto.BackstageCommentQueryDTO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author 贾晓晨
 * @version 1.0
 */
@Mapper
public interface BackstageCommentMapper {

    void deleteArticle(List<Integer> ids);

    List<ArticleCommentDTO> getTopComments(BackstageCommentQueryDTO backstageCommentQueryDTO);

    List<ArticleCommentDTO> getChildCommentsByHeadIds(@Param("headIds") List<Integer> topCommentId,
                                                      @Param("secondContent") String secondContent);

    ArticleCommentDTO getCommentById(Integer id);

    void batchDeleteCommentsByIds(@Param("ids") List<Integer> ids);

    void batchDeleteChildCommentsByHeadIds(@Param("headIds") List<Integer> headIds);
}
